Skip to content

Figure.pygmtlogo: Increase the gap around the vertical red line and arrow#4635

Merged
seisman merged 2 commits into
pygmtlogofrom
pygmtlogo-gap-thickness
May 11, 2026
Merged

Figure.pygmtlogo: Increase the gap around the vertical red line and arrow#4635
seisman merged 2 commits into
pygmtlogofrom
pygmtlogo-gap-thickness

Conversation

@seisman
Copy link
Copy Markdown
Member

@seisman seisman commented May 11, 2026

Currently, the gap between the vertical red line and the outline shape is set to thick_comp / 2, i.e., half the thickness of the compass line. This value was chosen arbitrarily.

This PR changes the gap from thick_comp / 2 to thick_gap, making it consistent with the gap between the letters G and M. The new gap is slightly larger, making it more visible when logos are small.

After this change, the variable thick_comp is used only for the compass lines.

Old New
image image

@seisman seisman changed the title Figure.pygmtlogo: Increase the gap around the vertical red line and a… Figure.pygmtlogo: Increase the gap around the vertical red line and arrow May 11, 2026
@seisman seisman force-pushed the pygmtlogo-gap-thickness branch from 560cfdb to 03bfd84 Compare May 11, 2026 09:03
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 11, 2026

Summary of changed images

This is an auto-generated report of images that have changed on the DVC remote

Status Path
modified pygmt/tests/baseline/test_pygmtlogo_circle_design.png
modified pygmt/tests/baseline/test_pygmtlogo_circle_no_wordmark.png

Image diff(s)

Details

Added images

Modified images

Path Old New
test_pygmtlogo_circle_design.png
test_pygmtlogo_circle_no_wordmark.png

Report last updated at commit 126b3de

@seisman seisman force-pushed the pygmtlogo-gap-thickness branch from 03bfd84 to 126b3de Compare May 11, 2026 09:13
Comment thread pygmt/src/pygmtlogo.py
mask = np.abs(t_x) <= (thick_gap + r4) / 2
return {"x": t_x[mask], "y": t_y[mask]}

def _vline_coords():
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I moved _vline_coords after _letter_t_coords, because the red vertical line at the top is more related to the letter T.

Comment thread pygmt/src/pygmtlogo.py
# x0, y0 is the same as in _letter_t_coords().
x0 = thick_gt / 2
y0 = 1.8 * x0 * np.sqrt(3)
# The background arrow is thick_comp wider than the letter T.
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replace thick_comp with thick_gap.

@seisman seisman added the maintenance Boring but important stuff for the core devs label May 11, 2026
@seisman seisman requested a review from yvonnefroehlich May 11, 2026 09:19
@seisman seisman added this to the 0.19.0 milestone May 11, 2026
@seisman seisman added the needs review This PR has higher priority and needs review. label May 11, 2026
@seisman seisman merged commit 5c7d482 into pygmtlogo May 11, 2026
18 of 23 checks passed
@seisman seisman deleted the pygmtlogo-gap-thickness branch May 11, 2026 10:24
@seisman seisman removed the needs review This PR has higher priority and needs review. label May 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance Boring but important stuff for the core devs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants